<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        div{
            width: 0;
            height: 0;
            /* 创建四个三角形 */
            /* border-top: 10px solid #000;
            border-left: 10px solid rgb(191, 41, 41);
            border-bottom: 10px solid rgba(26, 196, 17, 0.762);
            border-right: 10px solid pink; */

            /* transparent透明 */
            border: 50px solid transparent;
            border-left: 50px  solid pink;
        }
        .k{
            position: relative;
            width: 100px;
            height: 200px;
            background-color: pink;
            margin: 0 auto;
        }
        .k .s{
            position: absolute;
    
           right:-21px;
            width: 0;
            height: 0;

           /* 为了兼容 */
            line-height: 0;
            font-size: 0;

            border: 8px solid transparent;
            border-left: 8px solid pink;
        }
       
    </style>
</head>
<body>
    
    <div></div>

    <div class="k">
        <div class="s"></div>
    </div>
</body>
</html>